#include <bits/stdc++.h>
using namespace std;

const int N=1e5+9;
int n;
int a[N]={0};
int b[N];
int MAXN=-1;

int main(){
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    cin>>n;
    int k;
    bool pd=true;
    for(int i=1;i<=n;i++){
        cin>>k;
        a[k]++;
        MAXN=max(MAXN,k);
        if(a[k]>1) pd=false;
    }
    if(pd==true){
        cout<<1<<endl;
        return 0;
    }
    int len=0;
    for(int i=1;i<=MAXN;i++){
        if(a[i]!=0){
            len++;
            b[len]=a[i];
            if(a[i]>1) pd=false;
        }
    }
    for(int i=2;i<=len;i++){
        int minn=min(b[i],b[i-1]);
        b[i]=b[i-1]+b[i]-minn;
    }
    cout<<b[len]<<endl;
    return 0;
}
